def func1(a):
    '可以用__doc__作为文档打印出'
    print('aaa')


print(func1.__doc__)

# help(str)

s = 'fejfe'


def ff(*param, base=3):
    result = 0
    for each in param:
        result += each

    if base != 5:
        result = result * 5

    print(result)


ff(1, 2, 3, 4, 5, base=5)


def shui():
    for each in range(100, 1000):
        temp = each
        sum = 0
        while temp:
            sum = sum + (temp % 10) ** 3
            temp = temp // 10
        if sum == each:
            print(each, end='\t')
shui()

def findstr(destStr, subStr):
    count = 0
    length = len(destStr)
    if subStr not in destStr:
        print('没在字符串里发现')
    else:

        for each in range(length - 1):
            if subStr[0] == destStr[each]:
                if subStr[1] == destStr[each + 1]:
                    count += 1
    print(subStr, '的出现次数为', count, '次')

findstr('ffoefjeofeoijfoefeoeoeo', 'eo')
